package com.ruoyi.system.service.impl;

import com.ruoyi.system.domain.Dongtai;
import com.ruoyi.system.mapper.DongtaiMapper;
import com.ruoyi.system.service.IDongtaiService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class DongtaiServiceImpl implements IDongtaiService {

    @Autowired
    private DongtaiMapper dongtaiMapper;

    @Override
    public Boolean add(Dongtai dongtai) {
      return  dongtaiMapper.insert(dongtai);
    }

    @Override
    public Boolean deleteById(Long id) {
        return dongtaiMapper.deleteById(id);
    }

    @Override
    public Boolean update(Dongtai dongtai) {
        return dongtaiMapper.updateById(dongtai);
    }

    @Override
    public Dongtai getById(Long id) {
        return dongtaiMapper.selectById(id);
    }
}
